bc9834
@@ -531,13 +531,13 @@
public class HBaseFsck extends Configured {
       List<HRegionInfo> regions = MetaScanner.listAllRegions(getConf(), false);
       final RegionBoundariesInformation currentRegionBoundariesInformation =
           new RegionBoundariesInformation();
+      Path hbaseRoot = FSUtils.getRootDir(getConf());
       for (HRegionInfo regionInfo : regions) {
+        Path tableDir = FSUtils.getTableDir(hbaseRoot, regionInfo.getTable());
         currentRegionBoundariesInformation.regionName = regionInfo.getRegionName();
         // For each region, get the start and stop key from the META and compare them to the
         // same information from the Stores.
-        Path path = new Path(getConf().get(HConstants.HBASE_DIR) + "/"
-            + Bytes.toString(regionInfo.getTable().getName()) + "/"
-            + regionInfo.getEncodedName() + "/");
+        Path path = new Path(tableDir, regionInfo.getEncodedName());
         FileSystem fs = path.getFileSystem(getConf());
         FileStatus[] files = fs.listStatus(path);
         // For all the column families in this region...
